home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 007 / qbtools1.arc / AEGETSNG.BAS < prev    next >
BASIC Source File  |  1987-01-11  |  768b  |  25 lines

  1. rem $linesize:132
  2. rem $title:'Application Engineer Standard Routines'
  3. rem $subtitle:'Get a single key depression and code type'
  4. '  Get.Single
  5. '  Sub Routine to wait until a key is pressed
  6. '  Two values are returned, first is the character code, and second is
  7. '  the character type.
  8. '                Include the COMMON values
  9. rem $include:'AESHARED.BAS'            
  10.     
  11. sub Get.Single ( ccode% , ctyp% ) static
  12.         ctyp%=0%
  13.         while ctyp%=0%
  14.             single.press$=""
  15.             call qprint(date$,1,1)
  16.             while single.press$=""
  17.                 single.press$=inkey$
  18.                 call qprint(time$,1,70)
  19.             wend
  20.             call qprint(date$,1,1)
  21.             ctyp%=len(single.press$)
  22.             ccode%=asc(mid$(single.press$,ctyp%))
  23.         wend
  24.     end sub
  25.